import { http } from '@/utils/http'
import type { OrderDetailParams } from '@/types/order'
// 模拟发货-内测版
// GET/member/order/consignment/{id}
export const getPayMockAPI = (data: { orderId: string }) => {
  return http({
    method: 'GET',
    url: '/pay/mock',
    data,
  })
}

// 订单详情---待发货---模拟发货
// GET /member/order/consignment/{id}
export const getMemberOrderConsignmentByIdAPI = (id: string) => {
  return http({
    method: 'GET',
    url: `/member/order/consignment/${id}`,
  })
}

// 确认收货
// PUT / member / order / { id } / receipt
export const putMemberOrderByIdReceiptAPI = (id: string) => {
  return http<OrderDetailParams>({
    method: 'PUT',
    url: `/member/order/${id}/receipt`,
  })
}
